<!doctype html>
<html>
<head>
<meta charset="utf-8">
<link href="/Public/admin/css/style.css" rel="stylesheet">
<link href="/Public/admin/css/font-awesome.min.css" rel="stylesheet">
<link href="/Public/plugin/select2/select2.css" rel="stylesheet">
<title>{$title}</title>
</head>

<body>
    <div class="breadNav">
        <ul class="breadNavBar">
            <li><i class="icon-home" style="font-size:16px"></i></li>
            <li><a href="javascript:;" onClick="parent.location.reload('/Admin/Index/index');">首页</a></li>
            <li>&gt;</li>
            <li><a href="/Admin/Question/index">题库管理</a></li>
            <li>&gt;</li>
            <li>题库列表</li>
        </ul>
    </div>
    <div style="clear:both;"></div>
    <div class="filter">
        <if condition="$catId neq ''">
            <div class="form-group">
                <a class="btn btn-primary btn-lg" id="addBtn" href="/Admin/Exam/addExam/catId/{$catId}"><i class="icon-plus"></i>&nbsp;导题</a>
            </div>
        </if>
    </div>
    <div class="tableBox">
    <table class="table" >
        <thead>
            <tr>
                <th width="3%"></th>
                <th>ID</th>
                <th class="w_20">题干</th>
                <th>答案</th>
                <th>题型</th>
                <th class="time">添加时间</th>
                <th>操作</th>
            </tr>
        </thead>
        <tbody id="dataInfo">
        	<volist name="examList" id="examList">
            <tr>
                <td><input type="checkbox" name="id[]" value="{$examList.id}"></td>
                <td>{$key+1}</td>
                <td class="leftT">{$examList.topic}</td>
                <td class="leftT">{$examList.answer}</td>
                <td>
                	<switch name="examList.type">
                        <case value="3"><span style="color:red">判断题</span></case>
                        <case value="2"><span style="color:green">多选题</span></case>
                        <case value="1"><span style="color:#C60">单选题</span></case>
                        <default />
                    </switch>  
                </td>
                <td>{$examList.addtime|date="Y-m-d H:i:s",###}</td>
                <td>
                    <a class="btn btn-primary" onclick="tanchu('/Admin/Exam/delExam/id/{$examList.id}');" ><i class="icon-remove"></i>&nbsp;删除</a>
                	<!--<a class="btn btn-primary exit" href="/Admin/Goods/goodsTotal/id/{$goodsList.id}"><i class="icon-bar-chart"></i>&nbsp;统计</a>-->
                </td>
            </tr>
            </volist>
            <tr>
                <td><input type="checkbox" id="areaSelAll"></td>
                <td colspan="10" align="left">
                <a class="btn btn-table" href="javascript:void(0);" class="allDel" onclick="allDel('/Admin/Exam/allDel');"><i class="icon-trash"></i>&nbsp;批量删除</a>
                </td>
            </tr>
        </tbody>
    </table>
    </div>
	<div class="pageBarBox">
		{$page}
	</div>
</body>
<script src="/Public/js/jquery.min.js?ver=1.8.3"></script>
<script src="/Public/admin/js/main.js"></script>
<script src="/Public/js/titleMes.js"></script>
<script src="/Public/plugin/select2/select2.min.js"></script>
<script src="/Public/plugin/layer/layer.js"></script>
<script>
window.alert = function(msg){
	layer.alert(msg);
};
function tanchu(url){
    if(confirm("确认要删除吗？")){
        location.href=url;
    }else{
        return false;
    }
}
</script>
</html>
